<template>
    <!-- 专辑页面 -->
    <div class="list-album-component-item">
        <router-link class="list-album-component-img"
                     :to="{name: 'Album', params: {channelid: info.content.channelId, albumid: info.content.id}}">
            <img v-if="info.content.albumCover"
                 v-lazy="addCmdUrl(info.content.albumCover,600,100) "/>
            <img v-else src="../assets/images/live_default.png"/>
            <img class="audio-img" src="../assets/images/audio_normalsize_icon.png" v-if="info.content.albumType==2"/>
            <img class="audio-img" src="../assets/images/list_videoalbum_icon.png" v-if="info.content.albumType==1"/>
            <div class="list-album-component-img-info" v-if="info.content.displayTime">
                <!-- <img src="../assets/images/bag.png" class="list-album-component-img-info-img"/>&nbsp;-->
                <span class="list-album-component-img-info-txt" >{{this.toCommonTimeAlbum(info.content.displayTime)}}</span>
            </div>
        </router-link>
        <router-link class="list-album-component-title"
                     :to="{name: 'Album', params: {channelid: info.content.channelId, albumid: info.content.id}}">
            {{info.content.albumName}}
        </router-link>
        <router-link class="list-album-component-info"
                     :to="{name: 'Index', params: {channelid: info.content.channelId}}">
            <div class="floatL">
                <img v-if="info.content.albumType==2" class="audio-info-img" src="../assets/images/tag_audio_icon.png"/>
                {{info.content.channelName}}
            </div>
            <div class="floatR">{{this.simpleNum(info.content.totalViewCount)}}看过</div>
            <div class="clearBoth"></div>
        </router-link>
    </div>
</template>

<script>
    export default {
        props: {
            info: {
                type: Object,
                default: function () {
                    return {};
                }
            },
        }
    }
</script>

<style>
    .list-album-component-item {
        padding: 0.4rem 0;
        margin: 0.4rem auto;
        border-bottom: 0.06rem solid #EDEDED;
    }

    .list-album-component-title {
        font-size: 1.0rem;
        /*font-weight: bold;*/
        line-height: 1.3rem;
        max-height: 2.6rem;
        color: #222222;
        overflow: hidden;
        text-overflow: ellipsis;
        display: -webkit-box;
        -webkit-line-clamp: 2;
        -webkit-box-orient: vertical;
        /*white-space: nowrap;*/
        text-decoration: none;
        font-family: "PingFangSC";
    }

    .list-album-component-img {
        display: block;
        width: 100%;
        margin: 0.3rem auto;
        padding-bottom: 56.25%;
        position: relative;
        /*float: left;*/
    }

    .list-album-component-img > img {
        width: 100%;
        height: 100%;
        position: absolute;
        object-fit: cover;
        left: 0;
        top: 0;
        z-index: 1;
    }

    .list-album-component-img .audio-img {
        width: 54px;
        height: 54px;
        position: absolute;
        left: 50%;
        top: 50%;
        margin-top: -27px;
        margin-left: -27px;
        z-index: 10;
    }

    .special-content-container-small .list-album-component-img .audio-img {
        width: 26px;
        height: 26px;
        position: absolute;
        left: 50%;
        top: 50%;
        margin-top: -13px;
        margin-left: -13px;
        z-index: 10;
    }

    .list-album-component-img-info {
        position: absolute;
        right: 0.4rem;
        bottom: 0.4rem;
        background-color: #000;
        opacity: 0.7;
        height: 1.4rem;
        border-radius: 444rem;
        color: #FFF;
        font-size: 0.9rem;
        line-height: 1.4rem;
        text-align: center;
        padding: 0 0.4rem;
        z-index: 10;
    }

    .list-album-component-img-info-img { /* 公文包图案 */
        width: 1.0rem;
        height: 1.0rem;
        display: inline-block;
        float: left;
        margin-top: 0.2rem;
    }

    .list-album-component-img-info-txt {
        display: inline-block;
        float: right;
        font-size: 0.5rem;
    }

    .list-album-component-info {
        font-size: 0.5rem;
        line-height: 1.4rem;
        color: #999999;
    }

    .special-content-container-small .list-album-component-info .floatL {
        text-align: left;
        width: 50%;
        overflow: hidden;
        text-overflow: ellipsis;
        white-space: nowrap;
        height: 1.4rem;
    }

    .special-content-container-small .list-album-component-info .floatR {
        text-align: right;
        width: 50%;
        overflow: hidden;
        text-overflow: ellipsis;
        white-space: nowrap;
        height: 1.4rem;
    }

    .audio-info-img {
        height: 1.1rem;
        position: relative;
        top: 4px;
    }

    .special-content-container-small .audio-info-img {
        display: none;
    }
</style>